package org.oep.jmingle;

public class MingleNode {
	private long lastSeen;
	private String name;
	private String address;
	private int bumps;
	
	MingleNode() {
		lastSeen = System.currentTimeMillis();
		name = new String();
		address = new String();
		bumps = 0;
	}
	
	MingleNode(String name, String address) {
		lastSeen = System.currentTimeMillis();
		this.name = name;
		this.address = address;
		bumps = 0;
	}
	
	public void setLastSeen(long time) {
		lastSeen = time;
	}
	
	public void setName(String name) {
		this.name = name;
	}
	
	public void setAddress(String address) {
		this.address = address;
	}
	
	public void setBumps(int bumps) {
		this.bumps = bumps;
	}
	
	public long getLastSeen() { return lastSeen; }
	public String getName() { return name; }
	public String getAddress() { return address; }
	public int getBumps() { return bumps; }
	
	public void markSeen() {
		lastSeen = System.currentTimeMillis();
	}
	
	public void bump() {
		bumps++;
	}
}
